/*
 *    Copyright (c) 2018-2025, boss All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the boss developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: boss
 */

package com.hopes.bizz.close.basic.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.hopes.bizz.common.core.validate.group.AddGroup;
import com.hopes.bizz.common.core.validate.group.UpdateGroup;
import com.hopes.boss.common.entity.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * 园区普通车辆信息
 *
 *
 * @author pig
 * @date 2023-10-23 17:28:41
 */
@Data
@TableName(value = "closed_general_car", excludeProperty = "tenantId")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "园区普通车辆信息")
public class ClosedGeneralCarEntity extends BaseEntity {

    private static final long serialVersionUID = 1L;


	/**
	* ID
	*/
    @TableId(type = IdType.ASSIGN_ID)
    @Schema(description="ID")
    private Long id;


	/**
	 * 类型 park -> 园区   company -> 企业
	 */
	@Schema(description="类型")
	private String type;

	/**
	* 人员ID
	*/
    @Schema(description="人员ID")
    private Long personId;

	/**
	* 车牌号
	*/
    @Schema(description="车牌号")
	@NotBlank(message = "车牌号为必填项", groups = {AddGroup.class, UpdateGroup.class})
	@Length(max = 20, message = "车牌号最大长度为:20", groups = {AddGroup.class, UpdateGroup.class})
    private String licencePlateNumber;

	/**
	* 车主
	*/
    @Schema(description="车主")
	@NotBlank(message = "车主姓名为必填项", groups = {AddGroup.class, UpdateGroup.class})
	@Length(max = 50, message = "车主姓名最大长度为:50", groups = {AddGroup.class, UpdateGroup.class})
    private String carOwner;

	/**
	* 联系电话
	*/
    @Schema(description="联系电话")
	@NotBlank(message = "联系电话为必填项", groups = {AddGroup.class, UpdateGroup.class})
	@Length(max = 20, message = "联系电话最大长度为:20", groups = {AddGroup.class, UpdateGroup.class})
    private String phone;



	/**
	* 车辆所属
	*/
    @Schema(description="车辆所属")
	@NotNull(message = "车辆所属为必填项")
    private Integer carBelong;

	/**
	* 通行类型
	*/
    @Schema(description="通行类型")
    private Integer passType;

	/**
	* 车辆类型
	*/
    @Schema(description="车辆类型")
	@NotNull(message = "车辆类型为必填项")
    private Integer carType;

	/**
	* 海康车辆ID
	*/
    @Schema(description="海康车辆ID")
    private String vehicleId;

	/**
	* 行驶证
	*/
    @Schema(description="行驶证")
	@NotBlank(message = "行驶证为必填项", groups = {AddGroup.class, UpdateGroup.class})
	@Length(max = 100, message = "行驶证最大长度为:100", groups = {AddGroup.class, UpdateGroup.class})
    private String vehicleLicense;

	/**
	* 同步标志
	*/
    @Schema(description="同步标志")
    private String syncFlag;

	/**
	* 是否启用
	*/
    @Schema(description="是否启用")
    private String useFlag;

	/**
	* 审核状态
	*/
    @Schema(description="审核状态")
    private Integer auditStatus;

	/**
	* 审核结果描述
	*/
    @Schema(description="审核结果描述")
    private String auditResultDesc;

	/**
	 * 申请时间
	 */
	@Schema(description = "申请时间")
	private Date applyTime;


	@Schema(description = "审核时间")
	private Date auditTime;

	/**
	* 是否在园区
	*/
    @Schema(description="是否在园区")
    private String inParkFlag;

	/**
	* 备注
	*/
    @Schema(description="备注")
    private String remark;

	/**
	 * 申请人Id
	 */
	@Schema(description="申请人Id")
	private Long applyUserId;

	/**
	* 机构ID
	*/
    @Schema(description="机构ID")
	@NotNull(message = "所属企业为必填项")
    private Long orgId;

}
